<!--侧边栏组件-->
<template>
    <el-menu
        :default-openeds="['1', '2']"
        style="min-height: 100%; overflow-x: hidden"
        background-color="rgb(48, 65, 86)"
        text-color="#fff"
        active-text-color="#ffd04b"
        :default-active="$route.path"
        :collapse-transition="false"
        :collapse="isCollapse"
        router
    >
        <!--系统名称-->
        <div style="height: 60px; line-height: 60px; text-align: center">
            <img
                src="../assets/logo.png"
                alt=""
                style="width: 20px; position: relative; top: 5px; right: 5px"
            />
            <b style="color: white" v-show="logoTextShow">elm后台管理系统</b>
        </div>

        <!--主页-->
        <el-menu-item index="/home">
            <template slot="title">
                <i class="el-icon-house"></i>
                <span slot="title">主页</span>
            </template>
        </el-menu-item>

        <el-menu-item index="/user_management">
            <i class="el-icon-user"></i>
            <span slot="title">用户管理</span>
        </el-menu-item>


        <el-submenu index="1">
            <template slot="title">
                <i class="el-icon-food"></i>
                <span slot="title">商家管理</span>
            </template>
            <el-menu-item index="/food_info_management">
                <i class="el-icon-info"></i>
                <span slot="title">商家食品管理</span>
            </el-menu-item>
            <el-menu-item index="/food_type_management">
                <i class="el-icon-sort"></i>
                <span slot="title">商家信息管理</span>
            </el-menu-item>
        </el-submenu>
<!--        &lt;!&ndash;导航栏二：账户管理&ndash;&gt;-->
<!--        <el-submenu index="2">-->
<!--            <template slot="title">-->
<!--                <i class="el-icon-food"></i>-->
<!--                <span slot="title">商品管理</span>-->
<!--            </template>-->
<!--            &lt;!&ndash;我创建的&ndash;&gt;-->
<!--            <el-menu-item index="/user_info">-->
<!--                <i class="el-icon-sold-out"></i>-->
<!--                <span slot="title">商品类型</span>-->
<!--            </el-menu-item>-->
<!--            &lt;!&ndash;我参与的&ndash;&gt;-->
<!--            <el-menu-item index="/update_password">-->
<!--                <i class="el-icon-info"></i>-->
<!--                <span slot="title">商品信息</span>-->
<!--            </el-menu-item>-->
<!--        </el-submenu>-->
        <el-menu-item index="/recycle_station">
            <i class="el-icon-delete"></i>
            <span slot="title">黑名单用户</span>
        </el-menu-item>
        <el-menu-item index="/food_recycle_station">
            <i class="el-icon-delete"></i>
            <span slot="title">食品回收站</span>
        </el-menu-item>
    </el-menu>
</template>

<script>
export default {
    // eslint-disable-next-line vue/multi-word-component-names
    name: "Aside",
    props: {
        isCollapse: Boolean,
        logoTextShow: Boolean,
    },
};
</script>

<style scoped>
</style>
